import 'package:flutter/material.dart';
import 'package:get/get.dart';

import 'i18n.dart' as i18n;
import 'router.dart' as router;

void main() async {
  WidgetsFlutterBinding.ensureInitialized();

  await i18n.init();
  var routers = router.buildRouters();

  runApp(GetMaterialApp(
      theme: ThemeData(
        // primarySwatch: Colors.blue,
        useMaterial3: true,
      ),
      debugShowCheckedModeBanner: false,
      translations: i18n.Messages(),
      locale: i18n.currentLocale,
      fallbackLocale: i18n.fallbackLocale,
      initialRoute: router.homeRouterPath,
      getPages: routers)
  );
}
